Optimal. Leaf size=237 \[ \frac {2 a^3 (803 A+710 B) \sin (c+d x)}{495 d \sqrt {a+a \cos (c+d x)}}+\frac {2 a^3 (209 A+194 B) \cos ^3(c+d x) \sin (c+d x)}{693 d \sqrt {a+a \cos (c+d x)}}-\frac {4 a^2 (803 A+710 B) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{3465 d}+\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a (803 A+710 B) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{1155 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.41, antiderivative size = 237, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 5, integrand size = 33, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.152, Rules used = {3055, 3060,
2838, 2830, 2725} \begin {gather*} \frac {2 a^3 (209 A+194 B) \sin (c+d x) \cos ^3(c+d x)}{693 d \sqrt {a \cos (c+d x)+a}}+\frac {2 a^3 (803 A+710 B) \sin (c+d x)}{495 d \sqrt {a \cos (c+d x)+a}}+\frac {2 a^2 (11 A+14 B) \sin (c+d x) \cos ^3(c+d x) \sqrt {a \cos (c+d x)+a}}{99 d}-\frac {4 a^2 (803 A+710 B) \sin (c+d x) \sqrt {a \cos (c+d x)+a}}{3465 d}+\frac {2 a (803 A+710 B) \sin (c+d x) (a \cos (c+d x)+a)^{3/2}}{1155 d}+\frac {2 a B \sin (c+d x) \cos ^3(c+d x) (a \cos (c+d x)+a)^{3/2}}{11 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2725
Rule 2830
Rule 2838
Rule 3055
Rule 3060
Rubi steps
\begin {align*} \int \cos ^2(c+d x) (a+a \cos (c+d x))^{5/2} (A+B \cos (c+d x)) \, dx &=\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}+\frac {2}{11} \int \cos ^2(c+d x) (a+a \cos (c+d x))^{3/2} \left (\frac {1}{2} a (11 A+6 B)+\frac {1}{2} a (11 A+14 B) \cos (c+d x)\right ) \, dx\\ &=\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}+\frac {4}{99} \int \cos ^2(c+d x) \sqrt {a+a \cos (c+d x)} \left (\frac {3}{4} a^2 (55 A+46 B)+\frac {1}{4} a^2 (209 A+194 B) \cos (c+d x)\right ) \, dx\\ &=\frac {2 a^3 (209 A+194 B) \cos ^3(c+d x) \sin (c+d x)}{693 d \sqrt {a+a \cos (c+d x)}}+\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}+\frac {1}{231} \left (a^2 (803 A+710 B)\right ) \int \cos ^2(c+d x) \sqrt {a+a \cos (c+d x)} \, dx\\ &=\frac {2 a^3 (209 A+194 B) \cos ^3(c+d x) \sin (c+d x)}{693 d \sqrt {a+a \cos (c+d x)}}+\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a (803 A+710 B) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{1155 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}+\frac {(2 a (803 A+710 B)) \int \left (\frac {3 a}{2}-a \cos (c+d x)\right ) \sqrt {a+a \cos (c+d x)} \, dx}{1155}\\ &=\frac {2 a^3 (209 A+194 B) \cos ^3(c+d x) \sin (c+d x)}{693 d \sqrt {a+a \cos (c+d x)}}-\frac {4 a^2 (803 A+710 B) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{3465 d}+\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a (803 A+710 B) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{1155 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}+\frac {1}{495} \left (a^2 (803 A+710 B)\right ) \int \sqrt {a+a \cos (c+d x)} \, dx\\ &=\frac {2 a^3 (803 A+710 B) \sin (c+d x)}{495 d \sqrt {a+a \cos (c+d x)}}+\frac {2 a^3 (209 A+194 B) \cos ^3(c+d x) \sin (c+d x)}{693 d \sqrt {a+a \cos (c+d x)}}-\frac {4 a^2 (803 A+710 B) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{3465 d}+\frac {2 a^2 (11 A+14 B) \cos ^3(c+d x) \sqrt {a+a \cos (c+d x)} \sin (c+d x)}{99 d}+\frac {2 a (803 A+710 B) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{1155 d}+\frac {2 a B \cos ^3(c+d x) (a+a \cos (c+d x))^{3/2} \sin (c+d x)}{11 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 1.10, size = 127, normalized size = 0.54 \begin {gather*} \frac {a^2 \sqrt {a (1+\cos (c+d x))} (124366 A+114640 B+(68552 A+69890 B) \cos (c+d x)+16 (1397 A+1625 B) \cos (2 (c+d x))+5720 A \cos (3 (c+d x))+8675 B \cos (3 (c+d x))+770 A \cos (4 (c+d x))+2240 B \cos (4 (c+d x))+315 B \cos (5 (c+d x))) \tan \left (\frac {1}{2} (c+d x)\right )}{27720 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.19, size = 142, normalized size = 0.60
method | result | size |
default | \(\frac {8 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) a^{3} \sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (-2520 B \left (\sin ^{10}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (1540 A +10780 B \right ) \left (\sin ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (-5940 A -18810 B \right ) \left (\sin ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (9009 A +17325 B \right ) \left (\sin ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (-6930 A -9240 B \right ) \left (\sin ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+3465 A +3465 B \right ) \sqrt {2}}{3465 \sqrt {a \left (\cos ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}\, d}\) | \(142\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.60, size = 207, normalized size = 0.87 \begin {gather*} \frac {22 \, {\left (35 \, \sqrt {2} a^{2} \sin \left (\frac {9}{2} \, d x + \frac {9}{2} \, c\right ) + 225 \, \sqrt {2} a^{2} \sin \left (\frac {7}{2} \, d x + \frac {7}{2} \, c\right ) + 756 \, \sqrt {2} a^{2} \sin \left (\frac {5}{2} \, d x + \frac {5}{2} \, c\right ) + 2100 \, \sqrt {2} a^{2} \sin \left (\frac {3}{2} \, d x + \frac {3}{2} \, c\right ) + 8190 \, \sqrt {2} a^{2} \sin \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} A \sqrt {a} + 5 \, {\left (63 \, \sqrt {2} a^{2} \sin \left (\frac {11}{2} \, d x + \frac {11}{2} \, c\right ) + 385 \, \sqrt {2} a^{2} \sin \left (\frac {9}{2} \, d x + \frac {9}{2} \, c\right ) + 1287 \, \sqrt {2} a^{2} \sin \left (\frac {7}{2} \, d x + \frac {7}{2} \, c\right ) + 3465 \, \sqrt {2} a^{2} \sin \left (\frac {5}{2} \, d x + \frac {5}{2} \, c\right ) + 8778 \, \sqrt {2} a^{2} \sin \left (\frac {3}{2} \, d x + \frac {3}{2} \, c\right ) + 31878 \, \sqrt {2} a^{2} \sin \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} B \sqrt {a}}{55440 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.34, size = 137, normalized size = 0.58 \begin {gather*} \frac {2 \, {\left (315 \, B a^{2} \cos \left (d x + c\right )^{5} + 35 \, {\left (11 \, A + 32 \, B\right )} a^{2} \cos \left (d x + c\right )^{4} + 5 \, {\left (286 \, A + 355 \, B\right )} a^{2} \cos \left (d x + c\right )^{3} + 3 \, {\left (803 \, A + 710 \, B\right )} a^{2} \cos \left (d x + c\right )^{2} + 4 \, {\left (803 \, A + 710 \, B\right )} a^{2} \cos \left (d x + c\right ) + 8 \, {\left (803 \, A + 710 \, B\right )} a^{2}\right )} \sqrt {a \cos \left (d x + c\right ) + a} \sin \left (d x + c\right )}{3465 \, {\left (d \cos \left (d x + c\right ) + d\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 3.04, size = 257, normalized size = 1.08 \begin {gather*} \frac {\sqrt {2} {\left (315 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \sin \left (\frac {11}{2} \, d x + \frac {11}{2} \, c\right ) + 385 \, {\left (2 \, A a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) + 5 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sin \left (\frac {9}{2} \, d x + \frac {9}{2} \, c\right ) + 495 \, {\left (10 \, A a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) + 13 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sin \left (\frac {7}{2} \, d x + \frac {7}{2} \, c\right ) + 693 \, {\left (24 \, A a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) + 25 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sin \left (\frac {5}{2} \, d x + \frac {5}{2} \, c\right ) + 2310 \, {\left (20 \, A a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) + 19 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sin \left (\frac {3}{2} \, d x + \frac {3}{2} \, c\right ) + 6930 \, {\left (26 \, A a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) + 23 \, B a^{2} \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sin \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} \sqrt {a}}{55440 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int {\cos \left (c+d\,x\right )}^2\,\left (A+B\,\cos \left (c+d\,x\right )\right )\,{\left (a+a\,\cos \left (c+d\,x\right )\right )}^{5/2} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________